home
***
CD-ROM
|
disk
|
FTP
|
other
***
search
/
Aminet 7
/
Aminet 7 - August 1995.iso
/
Aminet
/
comm
/
mebbs
/
flofix10.lha
/
FlowFix.rexx
< prev
Wrap
OS/2 REXX Batch file
|
1995-01-01
|
2KB
|
54 lines
/* Add Carret to HLO and FLO flow files for Mebbsnet if using Trapdoor */
FixDir = "Ram:"
FixFile = "ListOfFlowFiles"
OutBoundDir = "Mail:Out/"
FilePattern = "*(C|F|H)LO"
TempFlowFile = "123.456.789.0.FLO"
NewNodeNumber = ""
NewFlowNode = ""
say " "
say "
FlowFix v1.0
by
Andrew Kendall
1-Jan-95"
say " "
address command "List >"FixDir||FixFile" "OutBoundDir||FilePattern" lformat %n"
address command "Sort "FixDir||FixFile" "FixDir||FixFile
open('ListFile',FixDir||FixFile,'R')
do forever
NodeNumber = readln('ListFile')
if length(NodeNumber) = 0 then do
say "End of Outbound Dir Scanning"
call close('ListFile')
nop
address command "Delete >NIL: "FixDir||FixFile
exit
end
say "Working on file :" NodeNumber
open('FloFile',OutBoundDir||NodeNumber,'R')
open('NewFile',OutBoundDir||TempFlowFile,'W')
do forever
FlowNode = readln('FloFile')
NewFlowNode = FlowNode
if length(FlowNode) = 0 then leave
if upper(left(right(FlowNode,3),2)) = "MO" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "TU" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "WE" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "TH" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "FR" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "SA" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(left(right(FlowNode,3),2)) = "SU" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if upper(right(FlowNode,3)) = "TIC" then if left(FlowNode,1) ~= "^" then NewFlowNode = "^"||FlowNode
if length(NewFlowNode) ~= 0 then writeln('NewFile',NewFlowNode)
NewFlowNode = ""
end
call close('NewFile')
call close('FloFile')
nop
address command "Delete >NIL: "OutBoundDir||NodeNumber
address command "Rename >NIL: "OutBoundDir||TempFlowFile OutBoundDir||NodeNumber
end
close('ListFile')
nop
address command "Delete "FixDir||FixFile